package com.example.server

import com.example.commons.core.AreaCode
import com.example.commons.core.idcard.IdCardGenerator
import kotlinx.serialization.builtins.ListSerializer
import kotlinx.serialization.json.Json
import org.junit.Test

class IdcardTest {


    @Test
    fun gen() {
//        val idcard = IdCardGenerator.getInstance().generate()
        val codeJson = AreaCode::class.java.getResourceAsStream("/static/id_card_area_code.json")
        val idcard = Json.decodeFromString(ListSerializer(AreaCode.serializer()), String(codeJson.readBytes()))
        println(idcard)
    }
}